package com.qpuc;

import android.os.CountDownTimer;
import android.widget.TextView;

public class CompteurLaSuite extends CountDownTimer {

    private TextView tv;
   
    public CompteurLaSuite(long millisInFuture, long countDownInterval, TextView tv){
        super(millisInFuture, countDownInterval);
        this.tv = tv;
    }
   
    public void onTick(long millisUntilFinished) {
        tv.setText(""+millisUntilFinished / 1000);
    }

    public void onFinish() {
        tv.setText("Time out!");
    }
  
}